<script setup lang="ts">
import {webInfoStore} from "@/store";
import {computed} from "vue";
import MyRunTime from "@/components/MyRunTime.vue";
const webInfo = webInfoStore()
const props = defineProps({
  fontColor: {
    type: String,
    default: '#999'
  }
})
const fontColor = computed(() => {
  return 'color: ' + props.fontColor
})
</script>

<template>
  <div class="footer" :style="fontColor">
    <span><a href="https://beian.miit.gov.cn/">{{ webInfo.getIcpInfo }}</a></span>
    <span>本站已运行：<MyRunTime/></span>
    <span>{{ webInfo.getCopyright }}</span>
  </div>
</template>

<style scoped lang="less">
.footer {
  width: 100%;
  height: 88px;
  color: inherit; // 继承父组件的color属性
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  & > span {
    font-size: 12px;
    & > a {
      height: 20px;
      text-decoration: none;
      line-height: 17px;
      color: inherit;
      &:hover { /* 增加hover状态样式，提升用户体验 */
        text-decoration: underline;
      }
    }
    &:nth-child(2) {
      height: 24px;
      font-size: 16px;
      line-height: 23px;
    }
  }
}
</style>
